﻿using System;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Windows;
using Draco.Studio.Host;
using Draco.Studio.Core;

namespace Draco.Studio
{
    /// <summary>
    /// Interaction logic for App.xaml
    /// </summary>
    public partial class App : Application
    {

        private ServiceMatrix m_Matrix;
        public App()
        {
            Console.WriteLine("Start program……");
            ShellHost host = new ShellHost();
            this.m_Matrix = new ServiceMatrix(host);
        }

        private void Application_Startup(object sender, StartupEventArgs e)
        {
             Window win = this.MainWindow;
        }
        protected override void OnStartup(StartupEventArgs e)
        {
            //SplashScreen s = new SplashScreen("界面1,jpg");
            //显示初始屏幕 自动关闭设置false
            //s.Show(false);
            //在3秒后关闭
            //s.Close(new TimeSpan(0, 0, 3));
            base.OnStartup(e);
            Window win = this.MainWindow;
        }
        private void Application_Exit(object sender, ExitEventArgs e)
        {
            if (m_Matrix != null)
            {
                m_Matrix.Dispose();
                m_Matrix = null;
            }
        }
    }
}
